let str = ''
let num = 0
let bool = false
let un = undefined
let nu = null

//原始值转布尔
console.log(Boolean(str));  // false
console.log(Boolean(num)); // 0 false   其他为 ture
console.log(Boolean(bool));  //false
console.log(Boolean(un));   //false
console.log(Boolean(nu));  //fasle
console.log(Boolean(NaN));  //fasle
console.log()

//原始值转数字
console.log(Number()); // 0
console.log(Number(str)); // NaN   
console.log(Number(bool)); // 0
console.log(Number(undefined)); // NaN
console.log(Number(nu)); // 0
console.log()

//原始值转字符串
console.log(String(num)); // -1
console.log(String(bool)); // false
console.log(String(un)); // undefined
console.log(String(NaN)); // NaN
console.log(String(Infinity)); // Infinity